package com.liao.order.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.liao.common.entity.order.OrdersEntity;
import com.liao.common.utils.PageUtils;
import com.liao.common.vo.order.OrderPreVo;
import com.liao.common.vo.order.OrderSaveReq;

import java.util.Map;

/**
 * 订单主表
 *
 * @author liao
 * @email 2858015963@qq.com
 * @date 2025-03-14 09:23:11
 */
public interface OrdersService extends IService<OrdersEntity> {

    PageUtils queryPage(Map<String, Object> params);

    /**
     * 添加订单
     *
     * @param orderSaveReq
     */
    void add(OrderSaveReq orderSaveReq);

    OrdersEntity getOrderByOrderId(String orderId);

    /**
     * 关闭订单
     *
     * @param order
     */
    void closeOrder(OrdersEntity order);

    /**
     * 支付订单
     *
     * @param orderId
     */
    void payOrder(String orderId);


    OrderPreVo getCartOrder();

}

